import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex)

const store = new Vuex.Store({
	state: {
		url: {
			upload: "https://bpapi.jinghushi.com/order.php/util/upload",
		},
		version: '',
		Location: {
			x: '',
			y: ''
		},
		city: '',
		address: '',
		level: {}
	},
	mutations: {
		upversion(state, info) {
			state.version = info
		},
		upLocation(state, info) {
			// 变更状�
			state.Location = {
				...info
			}
		},
		upcity(state, info) {
			state.city = info
		},
		upaddress(state, info) {
			state.address = info
		},
		uplevel(state, info) {
			state.level = info
		},
	},
	actions: {

	}
})

export default store